SearchContext

public interface SearchContext

Base interface for search methods that must be inherited by the DOM interfaces that want to have search mechanisms.

Inheritors

Functions

Link copied to clipboard
public final Element findByClassName(String className)
public final Element findByClassName(String className)

Returns the first Element found in the current search context by the given className, if any.

Link copied to clipboard
public final Element findByCssSelector(String cssSelector)
public final Element findByCssSelector(String cssSelector)

Returns the first Element found in the current search context by the given cssSelector, if any.

Link copied to clipboard
public final Element findById(String id)
public final Element findById(String id)

Returns the first Element found in the current search context by the given id, if any.

Link copied to clipboard
public final Element findByName(String name)
public final Element findByName(String name)

Returns the first Element found in the current search context by the given name, if any.

Link copied to clipboard
public final Element findByTagName(String tagName)
public final Element findByTagName(String tagName)

Returns the first Element found in the current search context by the given tagName, if any.

Link copied to clipboard
public abstract Optional<Element> findElementByClassName(String className)
Returns the first Element object found in the current search context by the given className.
Link copied to clipboard
public abstract Optional<Element> findElementByCssSelector(String cssSelector)
Returns the first Element object found in the current search context by the given cssSelector.
Link copied to clipboard
public abstract Optional<Element> findElementById(String id)
Returns the first Element object found in the current search context by the given id.
Link copied to clipboard
public abstract Optional<Element> findElementByName(String name)
Returns the first Element object found in the current search context by the given name.
Link copied to clipboard
public abstract Optional<Element> findElementByTagName(String tagName)
Returns the first Element object found in the current search context by the given tagName.
Link copied to clipboard
public abstract List<Element> findElementsByClassName(String className)
Returns an immutable list of the Element objects found in the current search context by the given className.
Link copied to clipboard
public abstract List<Element> findElementsByCssSelector(String cssSelector)
Returns an immutable list of the Element objects found in the current search context by the given cssSelector.
Link copied to clipboard
public abstract List<Element> findElementsById(String id)
Returns an immutable list of the Element objects found in the current search context by the given id.
Link copied to clipboard
public abstract List<Element> findElementsByName(String name)
Returns an immutable list of the Element objects found in the current search context by the given name.
Link copied to clipboard
public abstract List<Element> findElementsByTagName(String tagName)
Returns an immutable list of the Element objects found in the current search context by the given tagName.
Link copied to clipboard
public final Element getByClassName(String className)
public final Element getByClassName(String className)

Returns the first Element found in the current search context by the given className.

Link copied to clipboard
public final Element getByCssSelector(String cssSelector)
public final Element getByCssSelector(String cssSelector)

Returns the first Element found in the current search context by the given cssSelector.

Link copied to clipboard
public final Element getById(String id)
public final Element getById(String id)

Returns the first Element found in the current search context by the given id.

Link copied to clipboard
public final Element getByName(String name)
public final Element getByName(String name)

Returns the first Element found in the current search context by the given name.

Link copied to clipboard
public final Element getByTagName(String tagName)
public final Element getByTagName(String tagName)

Returns the first Element found in the current search context by the given tagName.